Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix failing debug assertion in JsonTypeInfo initialization #67334

Merged

Conversation

eiriktsarpalis
Copy link
Member

@eiriktsarpalis eiriktsarpalis commented Mar 30, 2022

Fixes a failing debug assertion in what seems to be a race when multiple threads attempt to initialize the JsonTypeInfo instance. It is likely that other initialization methods are impacted by the same issue, this PR is to unblock the CI issues as reported in #60962.

The initialization logic should be refactored so that metadata instances get initialized by a single thread, which will likely be done in conjunction with the work for #63686 cc @krwq.

Fix #60962.

@ghost
Copy link

ghost commented Mar 30, 2022

Tagging subscribers to this area: @dotnet/area-system-text-json, @gregsdennis
See info in area-owners.md if you want to be subscribed.

Issue Details

Fixes a failing debug assertion in what seems to be a race when multiple threads attempt to initialize the JsonTypeInfo instance. It is likely that other initialization methods are impacted by the same issue, this PR is to unblock the CI issues as reported in #60962.

The initialization logic should be refactored so that metadata instances get initialized by a single thread, which will likely be done in conjunction with the work for #63686 cc @krwq.

Fix #60962.

Author: eiriktsarpalis
Assignees: -
Labels:

area-System.Text.Json

Milestone: -

@eiriktsarpalis eiriktsarpalis added this to the 7.0.0 milestone Mar 30, 2022
@eiriktsarpalis eiriktsarpalis merged commit 203a901 into dotnet:main Mar 30, 2022
@eiriktsarpalis eiriktsarpalis deleted the fix-failing-jsontypeinfo-assertion branch March 30, 2022 15:10
@ghost ghost locked as resolved and limited conversation to collaborators Apr 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
2 participants